<template>
  <div>
    <div>
      <div v-show="mark"
           class="item-tip"></div>
      <div v-show="hasClose"
           class="item-close">
        <Button size="small"
                type="text"
                icon="close"
                @click="$emit('close',data.index)"></Button>
      </div>
      <span class="field-copy click-to-copy">{{data.row.contract_code}}
      </span>
      <span class="copy-tip">
        <i class="ivu-icon ivu-icon-ios-copy"></i>
      </span>
    </div>
    <div class="blue">
      <Icon type="ios-telephone"></Icon> {{data.row.debtor_name}} {{data.row.mobile}}
    </div>
    <div>
      {{data.row.org_name}} {{data.row.collector_name}}
    </div>
    <div>逾期欠款总额
      <span class="red">{{data.row.loan_balance || 0}}</span>
    </div>
    <div class="gray"
         v-if="data.row.collect_start_date">
      <Icon type="clock"></Icon> {{toDate(data.row.collect_start_date)}}-{{toDate(data.row.collect_end_date)}}</div>
  </div>
</template>

<script>
import Time from '@/common/time';

export default {
	props: {
		data: {},
		mark: {},
		hasClose: {},
	},
	methods: {
		toDate(s) {
			return Time.toDate(s);
		},
	},
};
</script>

<style>

</style>
